package com.legendshop.openportal.sdk.model.request.v4;

import com.legendshop.openportal.sdk.annotation.EnumValid;
import com.legendshop.openportal.sdk.model.BaseRequest;
import com.legendshop.openportal.sdk.model.constants.AccountTypeEnum;
import io.swagger.annotations.ApiModelProperty;
import lombok.Data;
import org.hibernate.validator.constraints.Length;

import javax.validation.constraints.NotBlank;
import javax.validation.constraints.NotNull;

import static com.legendshop.openportal.sdk.model.constants.ApiPathConstantsV4.USER_FORCE_LOGOUT_V4;

/**
 * 用户信息查询
 */
@Data
public class UserForceLogoutV4Request extends BaseRequest {

    @ApiModelProperty(value = "店铺ID", required = true)
    @NotNull(message = "店铺ID不能为空")
    private Long shopId;

    @ApiModelProperty(value = "账号ID", required = true)
    @Length(max = 64, message = "账号ID长度不能超过64位")
    @NotBlank(message = "账号ID不能为空")
    private String accountId;

    @ApiModelProperty(value = "账号类型", notes = "MOBILE=手机号、ID=用户ID", required = true)
    @EnumValid(target = AccountTypeEnum.class, message = "账号类型不能为空")
    private String accountType;

    @Override
    public String getApiPath() {
        return USER_FORCE_LOGOUT_V4;
    }
}
